<div class="row">
    <div ng-controller="mainCtrl" class=" containerDisPlay col-md-3 col-lg-3">
        <div class="list-group">
            <a href="#/tasks/all" ng-class="{active:querystr=='/tasks/all'}" class="list-group-item">
    全部任务
     <span class="badge">{{totalCount}}</span>
  </a>
            <a href="#/tasks/no" ng-class="{active:querystr=='/tasks/no'}" class="list-group-item">未完成
                     <span class="badge-ncomplete badge">{{ncompleteCount}}</span>
                </a>
            <a href="#/tasks/yes" ng-class="{active:querystr=='/tasks/yes'}" class="list-group-item">已完成
                     <span class="badge-complete badge">{{completeCount}}</span>
                </a>

        </div>
    </div>
    <div class="col-xs-12 col-sm-12 col-md-9 col-lg-9">
        <div class="panel panel-primary">
            <div class="panel-heading">
                <span class="panel-title">便签</span>

                <button type="button" ng-click="logout()" class="pull-right btn btn-danger btn-xs">
                        注销&nbsp;<span class="glyphicon glyphicon-off"></span>
                        </button>
                <div class="pull-right btn btn-info btn-xs">
                    {{userinfo.username}}&nbsp;<span class="glyphicon glyphicon-user"></span>
                </div>
            </div>
            <div class="panel-body">

                <form ng-show="!querystr.complete" ng-submit="addTask()" class="form">
                    <input type="text" ng-model="taskInput" ng-required="true" class="form-control" id="" placeholder="请输入一个任务">
                </form>
                <table class="table table-bordered table-striped table-hover table-condensed ">
                    <thead>
                        <tr>
                            <td>
                                <input type="checkbox" value="">
                            </td>
                            <td>
                                待办事项
                            </td>
                            <td>
                                编辑
                            </td>
                        </tr>
                    </thead>
                    <tbody>
                        <tr ng-repeat="task in tasks">
                            <td>
                                <input type="checkbox" ng-disabled="Edit.CurrentId==task._id && Edit.isEditing" ng-model="task.complete" ng-change="UpdateTask(task)" value="">
                            </td>
                            <td ng-show="!Edit.isEditing || Edit.CurrentId!=task._id" ng-clas>{{task.task}}</td>
                            <td ng-show="Edit.CurrentId==task._id && Edit.isEditing">
                                <input type="text" ng-model="task.task" ng-required="true" class="form-control input-sm">
                            </td>
                            <td ng-show="!Edit.isEditing || Edit.CurrentId!=task._id">
                                <button type="button" ng-click="EditTask(task)" ng-disabled="task.complete" class="btn btn-xs btn-info">编辑</button>
                                <button type="button" ng-click="DelTask(task)" class="btn btn-xs btn-danger">删除</button>
                            </td>
                            <td ng-show="Edit.CurrentId==task._id && Edit.isEditing">
                                <button type="button" ng-class="{disabled:task.complete}" ng-click="UpdateTask(task)" class="btn btn-xs btn-info">更新</button>
                                <button type="button" ng-click="CacelEdit()" class="btn btn-xs btn-danger">取消</button>

                            </td>
                        </tr>
                    </tbody>
                </table>

            </div>
        </div>
    </div>
</div>